@using TaskManager.Web.Extensions
@model TaskManager.Web.ViewModels.Task.TaskCreateModel
@{
    ViewBag.Title = "Create New Task";
}
@using (Html.BeginForm())
{
    @Html.ValidationSummary(true)
    <fieldset>
        @Html.NameAndTextBoxFor("Summary", model => model.Summary, new { @class = "xlarge" })
        @Html.NameAndDropDownListFor("Project", model => model.ProjectId, ViewBag.Projects as SelectList, "None", new { @class = "large" })
        @Html.NameAndTextAreaFor("Description", model => model.Description, new { rows = 3, @class = "xlarge" })
        @Html.NameAndDropDownListFor("Assignee", model => model.AssigneeId, ViewBag.Users as SelectList, "None", new { @class = "large" })
        @Html.NameAndDropDownListFor("Priority", model => model.Priority, new SelectList(new[] { 0, 1, 2, 3, 4 }), "None", new { @class = "large" })
        <p>
            <div class="row">
                <div class="span1" style="width: auto">
                    <input type="submit" class="btn primary form-action-btn" value="Create" id="Create" />
                </div>
                <div class="span1" style="width: auto">
                    @Html.ActionLink("Cancel", "Index", null, new { @class = "btn secondary" })
                </div>
            </div>            
        </p>
    </fieldset>
}